{
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 4,
   "id": "b9a6a19c-8f6f-4916-8dcb-20f23db3c216",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "158\n"
     ]
    }
   ],
   "source": [
    "hq_hosts = [(\"长城国瑞电信1\", \"218.85.139.19\", 7709),\n",
    "(\"长城国瑞电信2\", \"218.85.139.20\", 7709),\n",
    "(\"长城国瑞网通\", \"58.23.131.163\", 7709),\n",
    "(\"上证云成都电信一\", \"218.6.170.47\", 7709),\n",
    "(\"上证云北京联通一\", \"123.125.108.14\", 7709),\n",
    "(\"上海电信主站Z1\", \"180.153.18.170\", 7709),\n",
    "(\"上海电信主站Z2\", \"180.153.18.171\", 7709),\n",
    "(\"上海电信主站Z80\", \"180.153.18.172\", 80),\n",
    "(\"北京联通主站Z1\", \"202.108.253.130\", 7709),\n",
    "(\"北京联通主站Z2\", \"202.108.253.131\", 7709),\n",
    "(\"北京联通主站Z80\", \"202.108.253.139\", 80),\n",
    "(\"杭州电信主站J1\", \"60.191.117.167\", 7709),\n",
    "(\"杭州电信主站J2\", \"115.238.56.198\", 7709),\n",
    "(\"杭州电信主站J3\", \"218.75.126.9\", 7709),\n",
    "(\"杭州电信主站J4\", \"115.238.90.165\", 7709),\n",
    "(\"杭州联通主站J1\", \"124.160.88.183\", 7709),\n",
    "(\"杭州联通主站J2\", \"60.12.136.250\", 7709),\n",
    "(\"杭州华数主站J1\", \"218.108.98.244\", 7709),\n",
    "(\"杭州华数主站J2\", \"218.108.47.69\", 7709),\n",
    "(\"义乌移动主站J1\", \"223.94.89.115\", 7709),\n",
    "(\"青岛联通主站W1\", \"218.57.11.101\", 7709),\n",
    "(\"青岛电信主站W1\", \"58.58.33.123\", 7709),\n",
    "(\"深圳电信主站Z1\", \"14.17.75.71\", 7709),\n",
    "(\"云行情上海电信Z1\", \"114.80.63.12\", 7709),\n",
    "(\"云行情上海电信Z2\", \"114.80.63.35\", 7709),\n",
    "(\"上海电信主站Z3\", \"180.153.39.51\", 7709),\n",
    "(\"招商证券深圳行情\", \"119.147.212.81\", 7709),\n",
    "(\"华泰证券(南京电信)\", \"221.231.141.60\", 7709),\n",
    "(\"华泰证券(上海电信)\", \"101.227.73.20\", 7709),\n",
    "(\"华泰证券(上海电信二)\", \"101.227.77.254\", 7709),\n",
    "(\"华泰证券(深圳电信)\", \"14.215.128.18\", 7709),\n",
    "(\"华泰证券(武汉电信)\", \"59.173.18.140\", 7709),\n",
    "(\"华泰证券(天津联通)\", \"60.28.23.80\", 7709),\n",
    "(\"华泰证券(沈阳联通)\", \"218.60.29.136\", 7709),\n",
    "(\"华泰证券(南京联通)\", \"122.192.35.44\", 7709),\n",
    "(\"华泰证券(南京联通)\", \"122.192.35.44\", 7709),\n",
    "(\"安信\", \"112.95.140.74\", 7709),\n",
    "(\"安信\", \"112.95.140.92\", 7709),\n",
    "(\"安信\", \"112.95.140.93\", 7709),\n",
    "(\"安信\", \"114.80.149.19\", 7709),\n",
    "(\"安信\", \"114.80.149.21\", 7709),\n",
    "(\"安信\", \"114.80.149.22\", 7709),\n",
    "(\"安信\", \"114.80.149.91\", 7709),\n",
    "(\"安信\", \"114.80.149.92\", 7709),\n",
    "(\"安信\", \"121.14.104.60\", 7709),\n",
    "(\"安信\", \"121.14.104.66\", 7709),\n",
    "(\"安信\", \"123.126.133.13\", 7709),\n",
    "(\"安信\", \"123.126.133.14\", 7709),\n",
    "(\"安信\", \"123.126.133.21\", 7709),\n",
    "(\"安信\", \"211.139.150.61\", 7709),\n",
    "(\"安信\", \"59.36.5.11\", 7709),\n",
    "(\"广发\", \"119.29.19.242\", 7709),\n",
    "(\"广发\", \"123.138.29.107\", 7709),\n",
    "(\"广发\", \"123.138.29.108\", 7709),\n",
    "(\"广发\", \"124.232.142.29\", 7709),\n",
    "(\"广发\", \"183.57.72.11\", 7709),\n",
    "(\"广发\", \"183.57.72.12\", 7709),\n",
    "(\"广发\", \"183.57.72.13\", 7709),\n",
    "(\"广发\", \"183.57.72.15\", 7709),\n",
    "(\"广发\", \"183.57.72.21\", 7709),\n",
    "(\"广发\", \"183.57.72.22\", 7709),\n",
    "(\"广发\", \"183.57.72.23\", 7709),\n",
    "(\"广发\", \"183.57.72.24\", 7709),\n",
    "(\"广发\", \"183.60.224.177\", 7709),\n",
    "(\"广发\", \"183.60.224.178\", 7709),\n",
    "(\"国泰君安\", \"113.105.92.100\", 7709),\n",
    "(\"国泰君安\", \"113.105.92.101\", 7709),\n",
    "(\"国泰君安\", \"113.105.92.102\", 7709),\n",
    "(\"国泰君安\", \"113.105.92.103\", 7709),\n",
    "(\"国泰君安\", \"113.105.92.104\", 7709),\n",
    "(\"国泰君安\", \"113.105.92.99\", 7709),\n",
    "(\"国泰君安\", \"117.34.114.13\", 7709),\n",
    "(\"国泰君安\", \"117.34.114.14\", 7709),\n",
    "(\"国泰君安\", \"117.34.114.15\", 7709),\n",
    "(\"国泰君安\", \"117.34.114.16\", 7709),\n",
    "(\"国泰君安\", \"117.34.114.17\", 7709),\n",
    "(\"国泰君安\", \"117.34.114.18\", 7709),\n",
    "(\"国泰君安\", \"117.34.114.20\", 7709),\n",
    "(\"国泰君安\", \"117.34.114.27\", 7709),\n",
    "(\"国泰君安\", \"117.34.114.30\", 7709),\n",
    "(\"国泰君安\", \"117.34.114.31\", 7709),\n",
    "(\"国信\", \"182.131.3.252\", 7709),\n",
    "(\"国信\", \"183.60.224.11\", 7709),\n",
    "(\"国信\", \"58.210.106.91\", 7709),\n",
    "(\"国信\", \"58.63.254.216\", 7709),\n",
    "(\"国信\", \"58.63.254.219\", 7709),\n",
    "(\"国信\", \"58.63.254.247\", 7709),\n",
    "(\"海通\", \"123.125.108.90\", 7709),\n",
    "(\"海通\", \"175.6.5.153\", 7709),\n",
    "(\"海通\", \"182.118.47.151\", 7709),\n",
    "(\"海通\", \"182.131.3.245\", 7709),\n",
    "(\"海通\", \"202.100.166.27\", 7709),\n",
    "(\"海通\", \"222.161.249.156\", 7709),\n",
    "(\"海通\", \"42.123.69.62\", 7709),\n",
    "(\"海通\", \"58.63.254.191\", 7709),\n",
    "(\"海通\", \"58.63.254.217\", 7709),\n",
    "(\"华林\", \"120.55.172.97\", 7709),\n",
    "(\"华林\", \"139.217.20.27\", 7709),\n",
    "(\"华林\", \"202.100.166.21\", 7709),\n",
    "(\"华林\", \"202.96.138.90\", 7709),\n",
    "(\"华林\", \"218.106.92.182\", 7709),\n",
    "(\"华林\", \"218.106.92.183\", 7709),\n",
    "(\"华林\", \"220.178.55.71\", 7709),\n",
    "(\"华林\", \"220.178.55.86\", 7709),\n",
    "('TradeX', '119.147.212.81', 7709),\n",
    "('阿里云华南', '120.79.210.76', 7709),\n",
    "('上证云广州电信', '58.63.254.247', 7709),\n",
    "('AZURE云', '40.73.76.10', 7709),\n",
    "('AZURE云SSL', '40.73.76.10', 443),\n",
    "('东莞移动', '120.234.57.15', 7709),\n",
    "('阿里云华东', '101.133.231.193', 7709),\n",
    "('上证云上海移动', '103.251.85.23', 7709),\n",
    "('上证云广州移动', '120.232.150.205', 7709),\n",
    "('上证云上海电信', '222.73.51.185', 7709),\n",
    "('上证云长沙电信', '175.6.43.87', 7709),\n",
    "('上证云成都电信', '218.6.170.91', 7709),\n",
    "('上证云北京联通', '123.125.108.9', 7709),\n",
    "('上海电信行情主站18', '218.80.243.92', 7709),\n",
    "('上海青云行情主站1', '139.198.183.71', 7709),\n",
    "('上海上证信息电信1', '222.73.139.169', 7709),\n",
    "('上海上证信息电信2', '101.226.180.76', 7709),\n",
    "('上海上证信息电信3', '101.226.180.77', 7709),\n",
    "('上海上证信息电信4', '101.226.180.78', 7709),\n",
    "('上海上证信息电信5', '101.226.180.79', 7709),\n",
    "('上海外高桥联通', '103.250.194.47', 7709),\n",
    "('上海外高桥移动', '183.195.147.74', 7709),\n",
    "('北京上证信息联通1', '123.125.108.82', 7709),\n",
    "('北京上证信息联通2', '123.125.108.72', 7709),\n",
    "('北京上证信息联通3', '123.125.108.73', 7709),\n",
    "('北京青云行情主站', '139.198.9.231', 7709),\n",
    "('广州上证信息电信1', '58.63.254.237', 7709),\n",
    "('广州上证信息电信2 ', '58.63.254.238 ', 7709),\n",
    "('广州上证信息电信3', '58.63.254.239 ', 7709),\n",
    "('广州上证信息电信4', '58.63.254.232', 7709),\n",
    "('广州上证信息电信5', '58.63.254.233', 7709),\n",
    "('广州上证信息电信6', '58.63.254.140', 7709),\n",
    "('广州上证信息电信7', '58.63.254.141', 7709),\n",
    "('广东青云行情主站', '139.198.126.46', 7709),\n",
    "('广州上证信息移动1', '120.232.150.196', 7709),\n",
    "('广州上证信息移动2', '120.232.150.198', 7709),\n",
    "('广州上证信息移动3', '120.232.150.199', 7709),\n",
    "('成都上证信息电信1', '182.131.3.235', 7709),\n",
    "('成都上证信息电信2', '182.131.3.236', 7709),\n",
    "('成都上证信息电信3', '182.131.3.237', 7709),\n",
    "('成都上证信息电信4', '182.131.3.238', 7709),\n",
    "('成都上证信息电信5', '182.131.3.239', 7709),\n",
    "('成都上证信息移动1', '117.175.57.163', 7709),\n",
    "('成都上证信息移动2', '117.175.57.164', 7709),\n",
    "('新疆电信1', '61.128.121.203', 7709),\n",
    "('新疆电信2', '61.128.121.235', 7709),\n",
    "('新疆上证信息电信1', '202.100.166.112', 7709),\n",
    "('新疆上证信息电信2', '202.100.166.113', 7709),\n",
    "('新疆上证信息电信3', '202.100.166.114', 7709),\n",
    "('新疆上证信息电信4', '202.100.166.115', 7709),\n",
    "('沈阳上证信息联通1', '124.95.141.7', 7709),\n",
    "('沈阳上证信息联通2', '124.95.141.8', 7709),\n",
    "('郑州上证信息联通1', '182.118.47.138', 7709),\n",
    "('郑州上证信息联通2', '182.118.47.143', 7709)]\t\n",
    "\n",
    "print(len(hq_hosts))\n"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": 6,
   "id": "01eca8dc-724d-485c-a246-7d6326afa276",
   "metadata": {},
   "outputs": [
    {
     "name": "stdout",
     "output_type": "stream",
     "text": [
      "155\n"
     ]
    }
   ],
   "source": [
    "set_hosts = {(hs[1],hs[2])for hs in hq_hosts }\n",
    "print(len(set_hosts))"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "id": "c3e79035-a028-4dec-949c-9289371bb2fc",
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3 (ipykernel)",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.11.8"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
